{% extends "base.html" %}
{% load i18n static %}
{% load crispy_forms_tags %}

{% block title %}更改密码{% endblock %}

{% block content_title %}<h1>更改密码</h1>{% endblock %}

{% if form.errors %}
<p class="errornote">
    {% if form.errors.items|length == 1 %}{% trans "Please correct the error below." %}{% else %}{% trans "Please
    correct the errors below." %}{% endif %}
</p>
{% endif %}

{% block content %}
<div class="container">
    <div class="row justify-content-center">
        <div class="col-md-6 col-lg-4 bg-white p-4">
        <p>请输入你的旧密码，为了安全起见，接着要输入两遍新密码，以便我们校验你输入的是否正确。</p>
        <form method="POST">
            {% csrf_token %}
            <fieldset class="form-group">
                {{ form|crispy }}
            </fieldset>
            <div class="form-group">
                <button class="btn btn-outline-secondary" type="submit">修改我的密码</button>
            </div>
        </form>
        </div>
    </div>
</div>
{% endblock %}
